package net.wantongtech.xa.uploadbasicinfo.dao;

import com.wtkj.dao.impl.BaseDataTemplate;
import com.wtkj.vo.dzzf.base.xxjh.MessageSend;
import org.springframework.jdbc.core.BeanPropertyRowMapper;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 处理旧系统批量扣款数据DAO
 *
 * @author MaShibo
 * 日期 :  2020/1/14
 */
@Repository
public class DealWithOldBatchPayDataDao extends BaseDataTemplate {


    public List<MessageSend> queryOldBatchPayData() {
        final String sql =
                "SELECT *\n" +
                        "  FROM ETC_MESSAGESEND A\n" +
                        " WHERE A.SEND NOT IN (1, 9)\n" +
                        "   AND A.MSGBODY NOT LIKE '%publishType%'\n" +
                        "   AND A.SIGNSOURCE = 1\n" +
                        "   AND A.CHANNELTYPE <> 'CCB'";
        return jdbcTemplate.query(sql, BeanPropertyRowMapper.newInstance(MessageSend.class));
    }


}
